<?php

class client extends CI_Controller {

	function __construct() {
		parent::__construct();
		$this -> load -> helper('url');
		$this -> load -> library('xmlrpc');
		$server_url = site_url('services/service');
		$this -> xmlrpc -> server($server_url, 80);
	}


	function index()
	{
		$this->xmlrpc->method('login');
		$request = array('test', 'test');
		$this->xmlrpc->request($request);
		//$this->xmlrpc->set_debug(TRUE);
		if (!$this->xmlrpc->send_request()) {
			$this->xmlrpc->display_error();
		} else {
			echo '<pre>';
			print_r($this->xmlrpc->display_response());
			echo '</pre>';
		}
		exit();
	}
}
?>